﻿using System;

namespace Terraria.Net.Sockets
{
	// Token: 0x02000154 RID: 340
	public interface ISocket
	{
		// Token: 0x06000EA1 RID: 3745
		void Close();

		// Token: 0x06000EA2 RID: 3746
		bool IsConnected();

		// Token: 0x06000EA3 RID: 3747
		void Connect(RemoteAddress address);

		// Token: 0x06000EA4 RID: 3748
		void AsyncSend(byte[] data, int offset, int size, SocketSendCallback callback, object state = null);

		// Token: 0x06000EA5 RID: 3749
		void AsyncReceive(byte[] data, int offset, int size, SocketReceiveCallback callback, object state = null);

		// Token: 0x06000EA6 RID: 3750
		bool IsDataAvailable();

		// Token: 0x06000EA7 RID: 3751
		void SendQueuedPackets();

		// Token: 0x06000EA8 RID: 3752
		bool StartListening(SocketConnectionAccepted callback);

		// Token: 0x06000EA9 RID: 3753
		void StopListening();

		// Token: 0x06000EAA RID: 3754
		RemoteAddress GetRemoteAddress();
	}
}
